<?php
namespace app\common\model;

class UserNews extends Base
{
    protected $name = 'user_news';

    public function getSexAttr($val)
    {
        if($val == 1){
            return '男';
        }else if($val == 2){
            return '女';
        }else{
            return '未知';
        }
    }
}